package nl.windgazer.arachne.services.yql;

import org.apache.tapestry5.json.JSONObject;

public class YQLRSSTwitterEntry extends YQLRSSEntryImp {

	public final static String SOURCE = "twitter_rss";

	public YQLRSSTwitterEntry(JSONObject o) {
		final String title = o.getString("title");
		this.auth = title.substring(0, title.indexOf(' '));
		this.title = this.desc = title.substring(getAuthor().length());
		this.link = o.getString("link");
		this.pub = getDateTime(o.getString("pubDate"));
	}

	@Override
	public String getSourceType() {
		return SOURCE;
	}

}
